import java.util.Scanner;

public class Text4 {
    public static void main(String[] args) {
        Scanner sc= new Scanner(System.in);
        String a = sc.nextLine();
        String b = sc.nextLine();
        char[] a1 = a.toCharArray();
        char[] a2 = b.toCharArray();

        int size= a1.length;
        for (int i=0;i<size;i++){
            for (int j=0;j<a2.length;j++){
                if (a1[i]==a2[j]){
                    for (int k = i; k <size-1; k++) {
                        a1[k]=a1[k+1];
                    }
                    i--;size--;j=a2.length;
                }
            }
        }

        for (int i =size;i<a1.length;i++){
            a1[i]=' ';
        }


        System.out.println(a1);
    }
}
